package lab02.test30;

public class Test30
{
    public static void main(String[] args) {
       double[] math=new double[4];
       double a,sum=0;
math[0]=77;
math[1]=88;
math[2]=99;
math[3]=66;

try {
    int j;

    for (j=0;j<=math.length;j++){
        sum=math[j]+sum;
    }
    a=sum/math.length;
    System.out.println("平均分为:"+a);
}
catch (Exception m){
    System.out.println(m);

}
    }


}
